.\" Man page generated from reStructuredText.
.
.
.nr rst2man-indent-level 0
.
.de1 rstReportMargin
\\$1 \\n[an-margin]
level \\n[rst2man-indent-level]
level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
-
\\n[rst2man-indent0]
\\n[rst2man-indent1]
\\n[rst2man-indent2]
..
.de1 INDENT
.\" .rstReportMargin pre:
. RS \\$1
. nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin]
. nr rst2man-indent-level +1
.\" .rstReportMargin post:
..
.de UNINDENT
. RE
.\" indent \\n[an-margin]
.\" old: \\n[rst2man-indent\\n[rst2man-indent-level]]
.nr rst2man-indent-level -1
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.TH "GDALCOMPARE" "1" "Feb 08, 2024" "" "GDAL"
.SH NAME
gdalcompare \-  Compare two images.
.SH SYNOPSIS
.INDENT 0.0
.INDENT 3.5
.sp
.nf
.ft C
gdalcompare.py [\-\-help] [\-\-help\-general]
               [\-dumpdiffs] [\-skip_binary] [\-skip_overviews]
               [\-skip_geolocation] [\-skip_geotransform]
               [\-skip_metadata] [\-skip_rpc] [\-skip_srs]
               [\-sds] <golden_file> <new_file>
.ft P
.fi
.UNINDENT
.UNINDENT
.SH DESCRIPTION
.sp
The \fBgdalcompare.py\fP script compares two GDAL supported datasets and
reports the differences. In addition to reporting differences to the
standard output the script will also return the difference count in its
exit value.
.sp
Image pixels, and various metadata are checked. There is also a byte by
byte comparison done which will count as one difference. So if it is
only important that the GDAL visible data is identical a difference
count of 1 (the binary difference) should be considered acceptable.
.INDENT 0.0
.TP
.B \-\-help
Show this help message and exit
.UNINDENT
.INDENT 0.0
.TP
.B \-\-help\-general
Gives a brief usage message for the generic GDAL commandline options and exit.
.UNINDENT
.INDENT 0.0
.TP
.B \-dumpdiffs
New in version 3.8.

.sp
Whether to output the difference in pixel content in a TIFF file in the
current directory.
.UNINDENT
.INDENT 0.0
.TP
.B \-skip_binary
New in version 3.8.

.sp
Whether to skip exact comparison of binary content.
.UNINDENT
.INDENT 0.0
.TP
.B \-skip_overviews
New in version 3.8.

.sp
Whether to skip comparison of overviews.
.UNINDENT
.INDENT 0.0
.TP
.B \-skip_geolocation
New in version 3.8.

.sp
Whether to skip comparison of GEOLOCATION metadata domain.
.UNINDENT
.INDENT 0.0
.TP
.B \-skip_geotransform
New in version 3.8.

.sp
Whether to skip comparison of geotransform matrix.
.UNINDENT
.INDENT 0.0
.TP
.B \-skip_metadata
New in version 3.8.

.sp
Whether to skip comparison of metadata
.UNINDENT
.INDENT 0.0
.TP
.B \-skip_rpc
New in version 3.8.

.sp
Whether to skip comparison of Rational Polynomial Coefficients (RPC) metadata domain.
.UNINDENT
.INDENT 0.0
.TP
.B \-skip_srs
New in version 3.8.

.sp
Whether to skip comparison of spatial reference systems (SRS).
.UNINDENT
.INDENT 0.0
.TP
.B \-sds
If this flag is passed the script will compare all subdatasets that
are part of the dataset, otherwise subdatasets are ignored.
.UNINDENT
.INDENT 0.0
.TP
.B <golden_file>
The file that is considered correct, referred to as the golden file.
.UNINDENT
.INDENT 0.0
.TP
.B <new_file>
The file being compared to the golden file, referred to as the new
file.
.UNINDENT
.sp
Note that the \fBgdalcompare.py\fP script (like all the other scripts)
can also be called as a library from python code: \fIfrom osgeo_utils import gdalcompare\fP\&.
The primary entry point is \fIgdalcompare.compare_db()\fP which takes a golden
\fIgdal.Dataset\fP and a new \fIgdal.Dataset\fP as arguments and returns a
difference count (excluding the binary comparison). The
\fIgdalcompare.compare_sds()\fP entry point can be used to compare
subdatasets.
.SH AUTHOR
Frank Warmerdam <warmerdam@pobox.com>
.SH COPYRIGHT
1998-2024
.\" Generated by docutils manpage writer.
.
